package com.itheima;

/*      方法一:
            Class.forName("全类名")
		方法二:
		    类名.class
		方法三:
		    对象.getClass()*/
public class Myflectdemo1 {
    public static void main(String[] args) throws ClassNotFoundException {
        //获取class对象方法
        //方法一:
        Class<?> class1 = Class.forName("com.itheima.Student");
        System.out.println(class1);
        //方法二:
        Class<Student> class2 = Student.class;
        System.out.println(class2);
        //方法三:
        Student student=new Student();
        Class<? extends Student> class3 = student.getClass();
        System.out.println(class3);
    }
}
